<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib uri="/struts-tags" prefix="s"%>
<%@taglib uri="/struts-dojo-tags" prefix="sx"%>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <script type="text/JavaScript" src="javascript.js"></script>
        <title>SCA - Manter Turma</title>
    </head>
    <body>
        <h1>MANTER TURMA - ${operacao}</h1>
        <s:form action="Turma">
            <s:hidden name="operacao" value="%{operacao}"></s:hidden>
            
            <s:textfield name="turma.codTurma" readonly="%{readOnlyCod}" label="Código da Turma" onkeyup="campoNumerico(this)" value="%{turma.codTurma}"></s:textfield>
            <s:select name="turma.disciplina.codDisciplina" readonly="%{readOnly}" label="Disciplna" listKey="codDisciplina" listValue="nome" 
                list="disciplinas" ></s:select>
            <s:select name="turma.professor.matricula" readonly="%{readOnly}" label="Professor" listKey="matricula" listValue="nome" 
                list="professores" ></s:select>
            <s:textfield name="turma.numVagas" readonly="%{readOnly}" label="Numero de Vagas" onkeyup="campoNumerico(this)" value="%{turma.numVagas}"></s:textfield>
            <s:textfield name="turma.numSala" readonly="%{readOnly}" label="Sala" onkeyup="campoNumerico(this)" value="%{turma.numSala}"></s:textfield>
            <s:textfield name="turma.ano" readonly="%{readOnly}" label="Ano" onkeyup="campoNumerico(this)" value="%{turma.ano}"></s:textfield>>
            <s:select name="turma.semestre" readonly="%{readOnly}" label="Semestre" list="semestres" ></s:select>
            <s:submit action="voltarTurma" value="Voltar"></s:submit>
            <s:submit action="confirmarTurma" value="Confimar"></s:submit>   
        </s:form>
    </body>
</html>